package com.yunkeji.system.domain.bo;

import com.yunkeji.common.core.domain.BaseEntity;
import com.yunkeji.common.core.validate.AddGroup;
import com.yunkeji.common.core.validate.EditGroup;

import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.util.Date;

import javax.validation.constraints.*;

/**
 * 充值明细业务对象 ykj_pay_detail
 *
 * @author zhang
 * @date 2024-07-10
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class PayDetailBo extends BaseEntity {

    /** 自增主键 */
    @NotNull(
            message = "自增主键不能为空",
            groups = {EditGroup.class})
    private Long id;

    /** 用户id */
    @NotNull(
            message = "用户id不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Long userId;

    /** 平台订单号 */
    @NotBlank(
            message = "平台订单号不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private String orderId;

    /** 第三方订单号 */
    @NotBlank(
            message = "第三方订单号不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private String thirdId;

    /** 客户端类型,1陌对安卓/3mo聊安卓,2陌对iOS/4mo聊 iOS */
    @NotNull(
            message = "客户端类型,1陌对安卓/3mo聊安卓,2陌对iOS/4mo聊 iOS不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Integer branch;

    /** 充值结果,1已支付/0未支付 */
    @NotNull(
            message = "充值结果,1已支付/0未支付不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Integer status;

    /** 备注 */
    @NotBlank(
            message = "备注不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private String remark;

    /** 充值前金币余额 */
    @NotNull(
            message = "充值前金币余额不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private BigDecimal beforeGoldBalance;

    /** 人民币充值金额 */
    @NotNull(
            message = "人民币充值金额不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private BigDecimal cnyPrice;

    /** 充值获得的金币 */
    @NotNull(
            message = "充值获得的金币不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private BigDecimal gold;

    /** 支付方式(微信支付宝花呗) */
    @NotNull(
            message = "支付方式(微信支付宝花呗)不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Integer payType;

    /** 充值后金币余额 */
    @NotNull(
            message = "充值后金币余额不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private BigDecimal afterGoldBalance;

    /** 充值类型1=金币2=会员 */
    @NotNull(
            message = "充值类型1=金币2=会员不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Integer rechargeType;

    /** 充值VIP获得月数 */
    @NotNull(
            message = "充值VIP获得月数不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Integer month;

    /** 充值VIP后剩余到期时间 */
    @NotNull(
            message = "充值VIP后剩余到期时间不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Date afterExpireTime;

    /** 充值VIP前剩余到期时间 */
    @NotNull(
            message = "充值VIP前剩余到期时间不能为空",
            groups = {AddGroup.class, EditGroup.class})
    private Date beforeExpireTime;

    private Long platformId;
    /**
     * 充值开始时间
     */
    private String payTimeStart;
    /**
     * 充值结束时间
     */
    private String payTimeEnd;
}
